@extends('layouts.home')
@extends('layouts.nav')
@extends('layouts.top')

@section('heading')
    <h3>
        文件系统
    </h3>
    <ul class="breadcrumb">
        <li>
            <a href="#">文件系统</a>
        </li>
        <li class="active"> 视频管理</li>
    </ul>
@endsection

@section('wrapper')
    @include('share.error')
    <div class="row">
        <div class="col-sm-12">
            <section class="panel">
                <header class="panel-heading">
                    视频列表
                    <a href="#" data-toggle="modal" class="btn btn-success pull-right">
                        同步云存储
                    </a>
                </header>
                <div class="panel-body">
                    <table class="table  table-hover general-table">
                        <thead>
                        <tr>
                            <th> 名称</th>
                            <th>类型</th>
                            <th>创建人</th>
                            <th>时间</th>
                            <th class="text-center">上传存储</th>
                        </tr>
                        </thead>
                        <tbody>
                        @foreach($files as $file)
                        <tr>
                            <td>
                                {{ $file->name }}
                            </td>
                            <td>{{ $file->mime_type }}</td>
                            <td>{{ $file->author->name }} </td>
                            <td>{{ $file->created_at }} </td>
                            <td class="text-center"><span class="label {{ $file->is_upload ? 'label-success' : 'label-danger' }} label-mini">{{ $file->is_upload ? '是' : '否' }}</span></td>
                        </tr>
                        @endforeach


                        </tbody>
                    </table>
                    <div>
                        <ul class="pagination pagination-lg">
                            {{ $files->links() }}
                        </ul>
                    </div>
                </div>

            </section>
        </div>
    </div>
@endsection